extends Node


@export var chest_grid: ItemsGrid
@export var bag_grid: ItemsGrid
@export var info_lbl: RichTextLabel



func _notification(what: int) -> void:
    if what == NOTIFICATION_WM_CLOSE_REQUEST:
        print("close window")
        print("save inventory")
        InventoryManager.save_inventory(chest_grid.inventory)
        InventoryManager.save_inventory(bag_grid.inventory)
        get_tree().quit()
